<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
    <table border="1" cellspacing="0" width="60%">
        <thead><tr><th>商品名</th><th>单价</th><th>类别</th>
            <th>生产日期</th><th>操作</th></tr></thead>
        <tbody>
            <tr th:each="product : ${pageInfo.list}">
                <td th:text="${product.name}"></td>
                <td th:text="${product.price}"></td>
                <td th:text="${product.type}"></td>
                <td th:text="${product.createDate}"></td>
                <td><a th:href="@{/thymeleaf/del(id=${product.id})}">删除</a>
                    <a th:href="@{/thymeleaf/findById(id=${product.id})}">修改</a>
                </td>
            </tr>
        </tbody>
    </table>
    <div>
        <a style="margin-left: 5px" th:each="i : ${#numbers.sequence(1,pageInfo.pages)}"
        th:text="${i}" th:href="@{/thymeleaf/findByItem(pageNO=${i},name=${name},startDate=${startDate},endDate=${endDate})}"></a>
    </div>

    <form action="/thymeleaf/findByItem">
        商品名：<input type="text" name="name" th:value="${name}"><br>
        起始日期：<input type="text" name="startDate" th:value="${startDate}"><br>
        结束日期：<input type="text" name="endDate" th:value="${endDate}"><br>
        <input type="submit" value="查询">
    </form>
    <a href="/html/product/addProduct.html">添加</a>

</body>
</html>